<template>
  <div id="recruitlist">
    <el-breadcrumb separator=">">
      <el-breadcrumb-item :to="{ path: '/' }">系统首页</el-breadcrumb-item>
      <el-breadcrumb-item :to="{ name: 'recruitUnitProjectList' }">公开招聘</el-breadcrumb-item>
    </el-breadcrumb>
    <section class="wboxs">
    <!--工具条-->
        <el-form :inline="true" :model="filters">
          <div>
            <el-form-item style="float:left">
              <span style="font-weight:bolder">{{ title }}</span>
            </el-form-item>
            <div style="float:right">
              <el-form-item label="单位名称">
                <el-input v-model="filters.unitName" placeholder="关键字" @change="searchList"></el-input>
              </el-form-item>
              <el-form-item>
                <el-button type="primary" @click="searchList" icon="el-icon-search">查询</el-button>
              </el-form-item>
            </div>
          </div>
        </el-form>
    </section>
    <section class="wboxd" style="margin-top:10px">
      <!--列表-->
      <h1>单位列表</h1>
      <el-table :data="selectionlist" highlight-current-row v-loading="listLoading" style="width: 100%;" :height="tableHeight" border id="selectionindexlist" row-key="personId"
        default-expand-all
        :tree-props="{children: 'children', hasChildren: 'hasChildren'}">
        <el-table-column label="单位" prop="unitName">
        </el-table-column>
        <el-table-column label="制定年度公开招聘计划">
          <el-table-column label="计划申报" width="60">
            <template slot-scope="scope">
              <el-badge style="float:right" v-if="scope.row.planDeclareNew&&scope.row.planDeclareState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.planDeclareState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.planDeclareState===1" :content="scope.row.planDeclareSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,1)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.planDeclareState===5" :content="scope.row.planDeclareSubmitTime+'退回，原因：'+scope.row.planDeclareRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip>
            </template>
          </el-table-column>
          <el-table-column label="计划下达" width="60">
            <template slot-scope="scope">
              <i v-if="scope.row.planReleaseState===0" class="custom icon_c_0" @click="doit(scope.row.id,2)" style="cursor: pointer;" />
              <el-tooltip v-else-if="scope.row.planReleaseState===1" :content="scope.row.planReleaseSubmitTime+'下达'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,2)" style="cursor: pointer;" />
              </el-tooltip>
            </template>
          </el-table-column>
        </el-table-column>
        <el-table-column label="制定年度公开招聘工作方案" width="80" align="center">
          <!-- <el-table-column label="岗位对接方案" width="60" v-if="type!=2"> -->
            <template slot-scope="scope">
              <!-- <el-badge style="float:right" v-if="scope.row.jobDockingNew&&scope.row.jobDockingState===1" is-dot class="item"> </el-badge> -->
              <div v-if="scope.row.jobDockingState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.jobDockingState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,3)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.jobDockingState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,3)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-tooltip v-else-if="scope.row.jobDockingState===5" :content="scope.row.jobDockingSubmitTime+'退回，原因：'+scope.row.jobDockingRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
          <!-- </el-table-column> -->
        </el-table-column>
        <el-table-column label="发布招聘岗位、资格条件等招聘信息" width="80" align="center">
          <!-- <el-table-column label="招聘公告" width="350"> -->
            <template slot-scope="scope">
              <div v-if="scope.row.announcementState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.announcementState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,4)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.announcementState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,4)" style="cursor: pointer;" /> 5/5</div>
              <!-- <i v-if="scope.row.announcementState===-1" :class="'custom icon_c_-1'" />
              <el-steps v-else :active="scope.row.announcementState===5?0:scope.row.announcementState" finish-status="success" :process-status="scope.row.announcementState===2?'finish':(scope.row.announcementState===5?'error':'process')">
                <el-step :title="scope.row.announcementState===5?'退回':'填报'" icon="el-icon-edit"></el-step>
                <el-step title="预审" icon="el-icon-s-claim"></el-step>
                <el-step title="终审" icon="el-icon-s-claim" v-if="scope.row.announcementState>=2&&scope.row.announcementState!==5" @click.native="doit(scope.row.id,4)" style="cursor: pointer;"></el-step>
                <el-step title="终审" icon="el-icon-s-claim" v-else></el-step>
                <el-step v-if="scope.row.announcementState===4" title="发布" icon="el-icon-s-order" @click.native="doit(scope.row.id,4)" style="cursor: pointer;"></el-step>
                <el-step v-else title="发布" icon="el-icon-s-order"></el-step>
              </el-steps> -->
            </template>
          <!-- </el-table-column> -->
        </el-table-column>
        <el-table-column label="审查应聘人员资格条件" width="80" align="center">
            <template slot-scope="scope">
              <div v-if="scope.row.interviewResultsState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.interviewResultsState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,5)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.interviewResultsState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,5)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-badge style="float:right" v-if="scope.row.interviewResultsNew&&scope.row.interviewResultsState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.interviewResultsState===-1" :class="'custom icon_c_-1'" />
              <i v-else-if="scope.row.interviewResultsState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.interviewResultsState===1" :content="scope.row.interviewResultsSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,6)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.interviewResultsState===5" :content="scope.row.interviewResultsSubmitTime+'退回，原因：'+scope.row.interviewResultsRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
        </el-table-column>
        <el-table-column label="考试、考察、体检">
          <el-table-column label="面试考官备案" width="80" align="center">
            <template slot-scope="scope">
              <div v-if="scope.row.interviewerFilingState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.interviewerFilingState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,6)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.interviewerFilingState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,6)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-badge style="float:right" v-if="scope.row.interviewerFilingNew&&scope.row.interviewerFilingState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.interviewerFilingState===-1" :class="'custom icon_c_-1'" />
              <i v-else-if="scope.row.interviewerFilingState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.interviewerFilingState===1" :content="scope.row.interviewerFilingSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,5)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.interviewerFilingState===5" :content="scope.row.interviewerFilingSubmitTime+'退回，原因：'+scope.row.interviewerFilingRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
          </el-table-column>
          <el-table-column label="面试成绩上传" width="80" align="center">
            <template slot-scope="scope">
              <div v-if="scope.row.interviewResultsState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.interviewResultsState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,7)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.interviewResultsState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,7)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-badge style="float:right" v-if="scope.row.interviewResultsNew&&scope.row.interviewResultsState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.interviewResultsState===-1" :class="'custom icon_c_-1'" />
              <i v-else-if="scope.row.interviewResultsState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.interviewResultsState===1" :content="scope.row.interviewResultsSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,6)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.interviewResultsState===5" :content="scope.row.interviewResultsSubmitTime+'退回，原因：'+scope.row.interviewResultsRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
          </el-table-column>
          <el-table-column label="考察" width="80" align="center">
            <template slot-scope="scope">
              <div v-if="scope.row.interviewResultsState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.interviewResultsState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,8)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.interviewResultsState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,8)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-badge style="float:right" v-if="scope.row.interviewResultsNew&&scope.row.interviewResultsState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.interviewResultsState===-1" :class="'custom icon_c_-1'" />
              <i v-else-if="scope.row.interviewResultsState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.interviewResultsState===1" :content="scope.row.interviewResultsSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,6)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.interviewResultsState===5" :content="scope.row.interviewResultsSubmitTime+'退回，原因：'+scope.row.interviewResultsRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
          </el-table-column>
          <el-table-column label="体检" width="80" align="center">
            <template slot-scope="scope">
              <div v-if="scope.row.interviewResultsState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.interviewResultsState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,9)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.interviewResultsState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,9)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-badge style="float:right" v-if="scope.row.interviewResultsNew&&scope.row.interviewResultsState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.interviewResultsState===-1" :class="'custom icon_c_-1'" />
              <i v-else-if="scope.row.interviewResultsState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.interviewResultsState===1" :content="scope.row.interviewResultsSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,6)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.interviewResultsState===5" :content="scope.row.interviewResultsSubmitTime+'退回，原因：'+scope.row.interviewResultsRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
          </el-table-column>
        </el-table-column>
        <el-table-column label="择优确定拟聘用人员" width="80" align="center">
          <!-- <el-table-column label="聘用人选备案" width="120"> -->
            <template slot-scope="scope">
              <div v-if="scope.row.candidateRegistrationState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.candidateRegistrationState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,10)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.candidateRegistrationState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,10)" style="cursor: pointer;" /> 5/5</div>
              <!-- <el-badge style="float:right" v-if="scope.row.candidateRegistrationNew&&scope.row.candidateRegistrationState===1" is-dot class="item"> </el-badge>
              <i v-if="scope.row.candidateRegistrationState===0" class="custom icon_c_0" />
              <el-tooltip v-else-if="scope.row.candidateRegistrationState===1" :content="scope.row.candidateRegistrationSubmitTime+'提交'" placement="top" :open-delay="600">
                <i :class="'custom icon_c_2'" @click="doit(scope.row.id,8)" style="cursor: pointer;" />
              </el-tooltip>
              <el-tooltip v-else-if="scope.row.candidateRegistrationState===5" :content="scope.row.candidateRegistrationSubmitTime+'退回，原因：'+scope.row.candidateRegistrationRemark" placement="top" :open-delay="600">
                <i :class="'custom icon_c_3'" />
              </el-tooltip> -->
            </template>
          <!-- </el-table-column> -->
        </el-table-column>
        <el-table-column label="公示拟聘用人员名单" width="80" align="center">
          <!-- <el-table-column label="拟聘人选公示" width="350"> -->
            <template slot-scope="scope">
              <div v-if="scope.row.candidateAnnouncementState===0" style="line-height:30px"><i class="custom icon_c_0" /> 0/5</div>
              <div v-else-if="scope.row.candidateAnnouncementState===1" style="line-height:30px"><i :class="'custom icon_c_5'" @click="doit(scope.row.id,11)" style="cursor: pointer;" /> 2/5</div>
              <div v-else-if="scope.row.candidateAnnouncementState===2" style="line-height:30px"><i :class="'custom icon_c_2'" @click="doit(scope.row.id,11)" style="cursor: pointer;" /> 5/5</div>
              <!-- <i v-if="scope.row.candidateAnnouncementState===-1" :class="'custom icon_c_-1'" />
              <el-steps v-else :active="scope.row.candidateAnnouncementState===5?0:scope.row.candidateAnnouncementState" finish-status="success" :process-status="scope.row.candidateAnnouncementState===2?'finish':(scope.row.candidateAnnouncementState===5?'error':'process')">
                <el-step :title="scope.row.candidateAnnouncementState===5?'退回':'填报'" icon="el-icon-edit"></el-step>
                <el-step title="预审" icon="el-icon-s-claim"></el-step>
                <el-step title="终审" icon="el-icon-s-claim" v-if="scope.row.candidateAnnouncementState>=2&&scope.row.candidateAnnouncementState!==5" @click.native="doit(scope.row.id,7)" style="cursor: pointer;"></el-step>
                <el-step title="终审" icon="el-icon-s-claim" v-else></el-step>
                <el-step v-if="scope.row.candidateAnnouncementState===4" title="发布" icon="el-icon-s-order" @click.native="doit(scope.row.id,7)" style="cursor: pointer;"></el-step>
                <el-step v-else title="发布" icon="el-icon-s-order"></el-step>
              </el-steps> -->
            </template>
          <!-- </el-table-column> -->
        </el-table-column>
      </el-table>
      <!-- <el-table :data="selectionlist" highlight-current-row v-loading="listLoading" style="width: 100%;" :height="tableHeight" border id="selectionindexlist" row-key="personId"
        default-expand-all
        :tree-props="{children: 'children', hasChildren: 'hasChildren'}">
        <el-table-column label="单位" prop="unitName">
        </el-table-column>
        <el-table-column label="计划申报" width="80">
          <template slot-scope="scope">
            <i v-if="scope.row.planDeclareState===0" class="custom icon_c_0" />
            <el-tooltip v-else-if="scope.row.planDeclareState===1" :content="scope.row.planDeclareSubmitTime+'提交'" placement="top" :open-delay="600">
              <i :class="'custom icon_c_2'" @click="doit(scope.row.id,1)" style="cursor: pointer;" />
            </el-tooltip>
            <el-tooltip v-else-if="scope.row.planDeclareState===5" :content="scope.row.planDeclareSubmitTime+'退回，原因：'+scope.row.planDeclareRemark" placement="top" :open-delay="600">
              <i :class="'custom icon_c_3'" />
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column label="计划下达" width="80">
          <template slot-scope="scope">
            <i v-if="scope.row.planReleaseState===0" class="custom icon_c_0" />
            <el-tooltip v-else-if="scope.row.planReleaseState===1" :content="scope.row.planReleaseSubmitTime+'下达'" placement="top" :open-delay="600">
              <i :class="'custom icon_c_2'" @click="doit(scope.row.id,2)" style="cursor: pointer;" />
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column label="岗位对接方案" width="110">
          <template slot-scope="scope">
            <i v-if="scope.row.batchType===2||scope.row.jobDockingState===-1" :class="'custom icon_c_-1'" />
            <i v-else-if="scope.row.jobDockingState===0" class="custom icon_c_0" />
            <el-tooltip v-else-if="scope.row.jobDockingState===1" :content="scope.row.jobDockingSubmitTime+'提交'" placement="top" :open-delay="600">
              <i :class="'custom icon_c_2'" @click="doit(scope.row.id,3)" style="cursor: pointer;" />
            </el-tooltip>
            <el-tooltip v-else-if="scope.row.jobDockingState===5" :content="scope.row.jobDockingSubmitTime+'退回，原因：'+scope.row.jobDockingRemark" placement="top" :open-delay="600">
              <i :class="'custom icon_c_3'" />
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column label="招聘公告" width="350">
          <template slot-scope="scope">
            <i v-if="scope.row.announcementState===-1" :class="'custom icon_c_-1'" />
            <el-steps v-else :active="scope.row.announcementState===5?0:scope.row.announcementState" finish-status="success" :process-status="(scope.row.announcementState===1)?'finish':(scope.row.announcementState===5?'error':'process')">
              <el-step :title="scope.row.announcementState===5?'退回':'填报'" icon="el-icon-edit"></el-step>
              <el-step v-if="scope.row.announcementState===1" title="预审" icon="el-icon-s-claim" @click.native="doit(scope.row.id,4)" style="cursor: pointer;"></el-step>
              <el-step v-else title="预审" icon="el-icon-s-claim"></el-step>
              <el-step title="终审" icon="el-icon-s-claim"></el-step>
              <el-step title="发布" icon="el-icon-s-order"></el-step>
            </el-steps>
          </template>
        </el-table-column>
        <el-table-column label="面试考官备案" width="110">
          <template slot-scope="scope">
            <i v-if="scope.row.batchType===2||scope.row.interviewerFilingState===-1" :class="'custom icon_c_-1'" />
            <i v-else-if="scope.row.interviewerFilingState===0" class="custom icon_c_0" />
            <el-tooltip v-else-if="scope.row.interviewerFilingState===1" :content="scope.row.interviewerFilingSubmitTime+'提交'" placement="top" :open-delay="600">
              <i :class="'custom icon_c_2'" @click="doit(scope.row.id,5)" style="cursor: pointer;" />
            </el-tooltip>
            <el-tooltip v-else-if="scope.row.interviewerFilingState===5" :content="scope.row.interviewerFilingSubmitTime+'退回，原因：'+scope.row.interviewerFilingRemark" placement="top" :open-delay="600">
              <i :class="'custom icon_c_3'" />
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column label="面试成绩上传" width="110">
          <template slot-scope="scope">
            <i v-if="scope.row.batchType===2||scope.row.interviewResultsState===-1" :class="'custom icon_c_-1'" />
            <i v-else-if="scope.row.interviewResultsState===0" class="custom icon_c_0" />
            <el-tooltip v-else-if="scope.row.interviewResultsState===1" :content="scope.row.interviewResultsSubmitTime+'提交'" placement="top" :open-delay="600">
              <i :class="'custom icon_c_2'" @click="doit(scope.row.id,6)" style="cursor: pointer;" />
            </el-tooltip>
            <el-tooltip v-else-if="scope.row.interviewResultsState===5" :content="scope.row.interviewResultsSubmitTime+'退回，原因：'+scope.row.interviewResultsRemark" placement="top" :open-delay="600">
              <i :class="'custom icon_c_3'" />
            </el-tooltip>
          </template>
        </el-table-column>
        <el-table-column label="拟聘人选公示" width="350">
          <template slot-scope="scope">
            <i v-if="scope.row.candidateAnnouncementState===-1" :class="'custom icon_c_-1'" />
            <el-steps v-else :active="scope.row.candidateAnnouncementState===5?0:scope.row.candidateAnnouncementState" finish-status="success" :process-status="(scope.row.candidateAnnouncementState===1)?'finish':(scope.row.candidateAnnouncementState===5?'error':'process')">
              <el-step :title="scope.row.candidateAnnouncementState===5?'退回':'填报'" icon="el-icon-edit"></el-step>
              <el-step v-if="scope.row.candidateAnnouncementState===1" title="预审" icon="el-icon-s-claim" @click.native="doit(scope.row.id,7)" style="cursor: pointer;"></el-step>
              <el-step v-else title="预审" icon="el-icon-s-claim"></el-step>
              <el-step title="终审" icon="el-icon-s-claim"></el-step>
              <el-step title="发布" icon="el-icon-s-order"></el-step>
            </el-steps>
          </template>
        </el-table-column>
      </el-table> -->
      <div class="block" style="background:#F5F7FA;overflow:hidden">
        <!-- <el-pagination :total="totalnum" :page-size="pageSize" @current-change="handleCurrentChange" :current-page="pageNum" @size-change="handleSizeChange" :page-sizes="[10, 20, 30, 50]" layout="total, sizes, prev, pager, next, jumper"></el-pagination> -->
        <div id="legent">
          <!-- <div><b>图例</b></div> -->
          <i class="custom icon_c_0"></i><div>未办理</div>
          <!-- <i class="custom icon_c_-1"></i><div>无需办理</div> -->
          <i class="custom icon_c_1"></i><div>待办理</div>
          <!-- <i class="custom icon_c_3"></i><div>已退回</div> -->
          <i class="custom icon_c_5"></i><div>部分完成</div>
          <i class="custom icon_c_2"></i><div>已完成</div>
        </div>
      </div>
    </section>
  </div>
</template>

<script>
export default {
  data () {
    return {
      title: '',
      type: '',
      typename: '',
      id: null,
      timestamp: '',
      selectStepVisible: false,
      changeType: '',
      substep: '',
      dongyipersonId: '',
      steppersonId: '',
      candidateReportpersonId: '',
      manageOpinionpersonId: '',
      necessarypersonId: '',
      tuijianpersonId: '',
      kaochapersonId: '',
      taolunpersonId: '',
      gongshipersonId: '',
      baobeipersonId: '',
      fawenpersonId: '',
      tanhuapersonId: '',
      tanhua2personId: '',
      xuanbupersonId: '',
      guidangpersonId: '',
      candidateReportdetailshow: false,
      manageOpiniondetailshow: false,
      necessarydetailshow: false,
      tuijiandetailshow: false,
      kaochadetailshow: false,
      taolundetailshow: false,
      gongshidetailshow: false,
      baobeidetailshow: false,
      fawendetailshow: false,
      tanhuadetailshow: false,
      tanhua2detailshow: false,
      xuanbudetailshow: false,
      guidangdetailshow: false,
      personId: '',
      dongyidetailshow: false,
      jdcchuzhang: '',
      chuzhangs: [],
      tasknum: '',
      filters: {
        status: 1,
        personName: '',
        unitName: '',
        year: null
      },
      selectionlist: [],
      totalnum: 0,
      pageNum: 1,
      pageSize: 20,
      listLoading: true,
      changeSizeFlag: false,
      unitName: '',
      necessaryItems: [],
      mangeDep: [],
      tableHeight: 100,
      userRoles: '',
      jdcuserlist: [],
      jdcsetting: [],
      jdc1: '',
      jdc2: '',
      jdc3: '',
      jdc4: '',
      username: ''
    }
  },
  methods: {
    ftypename (type) {
      switch (type) {
        case 1:
          return '应届毕业生招聘'
        case 2:
          return '在职人员招聘'
        case 3:
          return '其他招聘'
      }
    },
    doit (id, step) {
      this.$router.push({name: 'recruitUnitAuditDetail', query: {step: step, unitBatchId: id}})
    },
    inRoles (str) {
      console.log(str)
      let arr = this.userRoles
      // arr = 'aaabbROLE_admin'
      if (arr.indexOf(str) === -1) {
        return false
      } else {
        return true
      }
    },
    // handleSizeChange (val) {
    //   this.changeSizeFlag = true
    //   this.pageNum = 1
    //   this.pageSize = val
    //   this.getList()
    // },
    // handleCurrentChange (val) {
    //   if (this.changeSizeFlag === false) {
    //     this.pageNum = val
    //     this.getList()
    //   }
    // },
    searchList () {
      this.getList()
    },
    getDetail () {
      this.$http
        .get(this.$http.defaults.recruitAPI + `api/recruitBusBatch/getById?id=` + this.id)
        .then(response => {
          this.type = response.data.result.batchType
          this.typename = this.ftypename(response.data.result.batchType)
          this.title = response.data.result.title
        })
        .catch(error => {
          this.$message({
            message: '获取失败:' + error,
            type: 'error'
          })
        })
    },
    getList () {
      let para = {
        batchId: this.id,
        unitName: this.filters.unitName
      }
      this.listLoading = true
      this.$http
        .post(this.$http.defaults.recruitAPI + `api/recruitBusUnitBatch/getListByBatchId`, para)
        .then(response => {
          this.listLoading = false
          this.selectionlist = response.data.result
        })
        .catch(error => {
          this.$message({
            message: '获取失败:' + error,
            type: 'error'
          })
          this.listLoading = false
        })
    },
    tableresize (obj) {
      var clientHeight = 0
      if (document.body.clientHeight && document.documentElement.clientHeight) {
        clientHeight = (document.body.clientHeight < document.documentElement.clientHeight) ? document.body.clientHeight : document.documentElement.clientHeight
      } else {
        clientHeight = (document.body.clientHeight > document.documentElement.clientHeight) ? document.body.clientHeight : document.documentElement.clientHeight
      }
      obj.$nextTick(function () {
        obj.tableHeight = clientHeight - 292
      })
    }
  },
  mounted () {
    this.id = 20
    this.getDetail()
    this.getList()
    this.tableresize(this)
    let _this = this
    window.onresize = function windowResize () {
      // 通过捕获系统的onresize事件触发我们需要执行的事件
      _this.tableresize(_this)
    }
  }
}
</script>
<style>
.selectioncontent{
  border-bottom:1px solid #333;
  padding:5px !important;
}
  .pointtab .el-badge__content.is-fixed{
    right: -5px;
    top:18px;
  }
  .pointtab{
    padding-right:22px;
  }
  .pointRadio .el-badge__content.is-fixed{
    right: -5px;
    top:6px;
  }
  .pointRadio .el-radio-button__inner{
    height:40px;
    padding-left:15px;
    padding-right:42px;
  }
#recruitlist .el-table--border td, .el-table--border th, .el-table__body-wrapper .el-table--border.is-scrolling-left~.el-table__fixed{
  border-bottom:1px solid #95B8E7;
}
#recruitlist .el-table td, #recruitlist .el-table th.is-leaf{
  border-right:1px solid #95B8E7;
}
  .wboxd .el-table th{
    font-weight: normal;
    background-image: linear-gradient(to bottom , #f8f8f8, #efefef);
    text-align: center;
    border-right: #95B8E7 solid 1px;
    border-bottom: #95B8E7 solid 1px;
    min-height: 30px;
    line-height:30px;
  }
  .wboxd .el-table td{
    padding:0;
    font-size:var(--size14) !important;
    line-height: 20px;
    font-family: '宋体',
  }
  .tableth{
    background-image: linear-gradient(to bottom , #f8f8f8, #efefef);
    height:33px;
  }
  #recruitlist .wboxs{
    height:45px;
    padding-top:10px;
  }
  #recruitlist .el-table__row{
    height: 50px;
  }
  #recruitlist #legent{
    float:right;
    margin-right: 20px;
  }
  #recruitlist #legent div{
    float:left;
    line-height: 42px;
    font-size:var(--size12);
  }
  #recruitlist #legent i{
    width: 30px;
    height: 30px;
    background-position: center center;
    background-repeat: no-repeat;
    float: left;
    display: block;
    margin:5px 0px 0 3px;
  }
  #recruitlist #selectionindexlist .cell i.custom{
    width: 30px;
    height: 30px;
    background-position: center center;
    background-repeat: no-repeat;
    float: center;
    display: block;
    margin:0 auto;
  }
  #recruitlist #selectionindexlist .cell button i{
    width: var(--size14);
    height: var(--size14);
  }
  #recruitlist .icon_c_0{
    background-image: url(../assets/icon_selection_index0.png)
  }
  #recruitlist .icon_c_1{
    background-image: url(../assets/icon_selection_index2.gif)
  }
  #recruitlist .icon_c_2{
    background-image: url(../assets/icon_selection_index1.png)
  }
  #recruitlist .icon_c_-1{
    background-image: url(../assets/icon_selection_index-1.png)
  }
  #recruitlist .icon_c_3{
    background-image: url(../assets/icon_selection_index3.png)
  }
  #recruitlist .icon_c_3a{
    background-image: url(../assets/icon_selection_index4t.png)
  }
  #recruitlist .icon_c_3b{
    background-image: url(../assets/icon_selection_index3b.png)
  }
  #recruitlist .icon_c_4{
    background-image: url(../assets/icon_selection_index4t.png)
  }
  #recruitlist .icon_c_5{
    background-image: url(../assets/icon_selection_index4r.png)
  }
  #recruitlist .icon_gd_0{
    background-image: url(../assets/icon_selection_gd0.png)
  }
  #recruitlist .icon_gd_1{
    background-image: url(../assets/icon_selection_gd1.gif)
  }
  #recruitlist .icon_gd_2{
    background-image: url(../assets/icon_selection_gd2.png)
  }
  #recruitlist .icon_gd_4{
    background-image: url(../assets/icon_selection_gd4.png)
  }
  #recruitlist .el-step__title.is-finish {
    color: #409EFF;
  }
  #recruitlist .el-step__title {
    font-size:12px;
    line-height: 22px;
    padding-left: 8px;
  }
  #recruitlist .el-steps{
    margin:10px 0;
  }
  .el-tooltip__popper.is-dark{
    font-size:var(--size18) !important;
  }
  .el-tabs--card>.el-tabs__header {
    border-bottom: 1px solid #9CA3B3;
  }
  .el-tabs--card>.el-tabs__header .el-tabs__nav {
    border: 1px solid #9CA3B3;
    border-bottom: 0;
  }
  .el-tabs--card>.el-tabs__header .el-tabs__item {
    border-left: 1px solid #9CA3B3;
    /* background-color: #F0F0F0; */
  }
  .el-tabs__item.is-active {
    color: #0000FF !important;
    font-weight: bolder !important;
    /* background-color: #fff !important; */
    /* border-bottom: 2px solid #9CA3B3 !important; */
  }
</style>
<style scoped>
  .el-tooltip__popper{
    font-size:var(--size) !important;
  }
  h1{
    font-size:var(--size16) !important;
    font-weight: bolder;
    height: 30px;
    border-bottom: 1px solid #95B8E7;
    font-family: '宋体';
    line-height: 30px;
    color: #000;
    padding-left:10px;
    background-image: linear-gradient(to bottom , #EEF4FF, #E0ECFF);
    margin:0;
  }
  .el-pagination{
    float: left;
    padding:7px 10px;
  }
  .wboxs{
    padding:5px 15px;
    width: calc(100% - 30px);
    background: #fff;
    border: 1px solid #95B8E7;
    margin:0 10px;
    overflow: hidden;
  }
  .wboxd{
    padding:0;
    width: calc(100% - 0px);
    background: #fff;
    border: 1px solid #95B8E7;
    margin:0 10px;
    overflow: hidden;
  }
</style>
